package test;

/**
 * @author chihb
 * @create-time 2024/6/20 11:43
 * @description
 */
public class PrimenNumber {
    public static void main(String[] args) {
        getNum(101,200);
    }
    //求1101到200的素数
    private static void getNum(int start,int end){
        for (int i = start; i <=end; i++) {
            boolean flag=true;
            for(int j=2;j<=i/2;j++){
                if(i%j==0){
                    flag=false;
                    break;
                }
            }
            if(flag){
                System.out.println(i);
            }
        }
    }
}
